require(["core", "jQuery", "coAjax", "hash_routie", "queryString", "href"], function(jSouper, $, coAjax, hash_routie, QueryString, href) {
	hash_routie.on("reply-item", function() {
		var queryString = new QueryString(location.hash);
		var message_id = queryString.get("id");
		if (!message_id) {
			alert("error", "意外的跳转访问~");
			return
		};
		coAjax.get(appConfig.open.message_by_id, {
			message_id: message_id
		}, function(result) {
			App.set("$Cache.replyItem.message", result.result);
		}, function(errorCode, xhr, errorMsg) {
			alert("error", errorMsg);
		});
	});
	App.set("$Cache.admin.reply_message",function (e,vm) {
		coAjax.put(appConfig.admin.reply_message,{
			message_id:App.get("$Cache.replyItem.message._id"),
			content:App.get("$Cache.replyItem.reply.content")
		},function (result) {
			alert("success","回复成功");
			App.set("$Cache.replyItem.message", result.result);
		});
	});
});